<script src="vue.js"></script>
<div id="app">
    <mcomponent name="this"></mcomponent>
</div>
<script>
     Vue.component('mcomponent',{
        data(){

        },
        props:['name'],
        template:'<p>我是自定义组件{{name}}</p>'
     });
     var vue=new Vue({
        el:'#app',
     });
</script>